package guiElements;

import java.awt.Color;
import java.util.ArrayList;

import javax.swing.JPanel;
import javax.swing.JToggleButton;

public class ResultsSortByPanel extends JPanel {
	
	private ArrayList<Fabric> fabricData;
	private JToggleButton nameButton, colorButton, patternButton;
	
	public ResultsSortByPanel(ArrayList<Fabric> fabricData){
		this.fabricData = fabricData;
		setBackground(Color.white);
		nameButton = new JToggleButton("Sort By Name");
		colorButton = new JToggleButton("Sort by Color");
		patternButton = new JToggleButton("Sort by Pattern");
		
		nameButton.setSelected(true);
		add(nameButton);
		add(colorButton);
		add(patternButton);
	}
	
	public ArrayList<Fabric> getFabricData() {
		return fabricData;
	}

	public void setFabricData(ArrayList<Fabric> fabricData) {
		this.fabricData = fabricData;
	}

	public JToggleButton getNameButton() {
		return nameButton;
	}

	public void setNameButton(JToggleButton nameButton) {
		this.nameButton = nameButton;
	}

	public JToggleButton getColorButton() {
		return colorButton;
	}

	public void setColorButton(JToggleButton colorButton) {
		this.colorButton = colorButton;
	}

	public JToggleButton getPatternButton() {
		return patternButton;
	}

	public void setPatternButton(JToggleButton patternButton) {
		this.patternButton = patternButton;
	}

}
